package com.acyouzi.leetcode.bit;

/**
 * Created by SUN on 2017/9/6.
 */
public class PowerofTwo {
  public boolean isPowerOfTwo(int n) {
    return n > 0 && Integer.bitCount(n) == 1;
  }
}
